<?php
    include('inc/db.php');
    include('template/_header.php')
?>
<div id="contact">
    <p class='search'><center>
        <label for="keywords">
            »
            <a href="list.php">由此查看所有文章</a>
            ，或者搜索：
        </label>
    <form method="get" action="">
        <input id="keywords" type="text" size="45" value="" name="keywords"/>
        <span class="submit">
            <input type="submit" value="搜索"/>
        </span>
        </form></center>
    </p>
<?php
    $query = "SELECT * "."FROM post "."ORDER BY id "." DESC LIMIT 0,20";
    $result = mysql_query($query);
    $ltq = mysql_query("SELECT * FROM post");
    $listings_total = mysql_num_rows($ltq);

    echo $listings_total.'篇文章';

    include('template/_footer.php');
?>

</div>

